![]() |
OPC-UA Embedded Server SDK
2.1.0
|
Functions | |
| void * | UAServer_Malloc (size_t size) |
| void * | UAServer_Calloc (size_t size) |
| void * | UAServer_Realloc (void *ptr, size_t size) |
| void | UAServer_Free (void *ptr) |
| void* UAServer_Malloc | ( | size_t | size | ) |
Allocate a block of memory from the SDK memory allocation subsystem
If the application needs to perform dynamic memory allocation it can use the SDK memory allocation subsystem rather than a general purpose heap (which in any case may not be available). The allocation must be less than UA_Configuration_Internals_t::MAX_ALLOCATION_SIZE_IN_BYTES specified in the runtime configuration (typically by 8 bytes).
| [in] | size | The size in bytes of the required block of memory. |
| void* UAServer_Calloc | ( | size_t | size | ) |
Allocate a block of memory from the SDK memory allocation subsystem and zero the block. The allocation must be less than UA_Configuration_Internals_t::MAX_ALLOCATION_SIZE_IN_BYTES specified in the runtime configuration (typically by 8 bytes).
| [in] | size | The size in bytes of the required block of memory. |
| void* UAServer_Realloc | ( | void * | ptr, |
| size_t | size | ||
| ) |
Increase or decrease the size of a previously allocated block of memory from the SDK memory allocation subsystem. The allocation must be less than UA_Configuration_Internals_t::MAX_ALLOCATION_SIZE_IN_BYTES specified in the runtime configuration (typically by 8 bytes).
| [in] | ptr | A pointer previously returned by one of the memory allocation routines. |
| [in] | size | The size in bytes of the required block of memory. |
| void UAServer_Free | ( | void * | ptr | ) |
Free a memory block previously allocated with UAServer_Malloc(), UAServer_Calloc() or UAServer_Realloc().
| [in] | ptr | The pointer previously returned by one of the memory allocation routines. |